home *** CD-ROM | disk | FTP | other *** search
/ The Atari Compendium / The Atari Compendium (Toad Computers) (1994).iso / files / prgtools / programm.ing / gfa / gfacode.arc / DEGINLIN.LST next >
Encoding:
File List  |  1990-10-10  |  1.1 KB  |  29 lines

  1. '  Include your DEGAS uncompressed picture INSIDE
  2. '  your GFA 3.0 source code, and make the user's life
  3. '  easier!
  4. '
  5. INLINE pic_add%,32066
  6. '  Place the cursor on the INLINE line above, then hit
  7. '  the [HELP] key.  You will get a little menu on the
  8. '  top of the screen.  Press [L] for Load, then use
  9. '  the file selector to choose your DEGAS picture.
  10. '  The pic is imbedded into your code.  pic_add% will now
  11. '  hold the start address of the picture.  (32066 is the
  12. '  length of a DEGAS file.)  You can have as many pics as
  13. '  you want, each in it's own INLINE statement, with different
  14. '  start-address variable names.  Pass the start address to
  15. '  the procedure below to view the picture.
  16. '
  17. '  An example:
  18. deg_view(pic_add%)  !  pic_add% is the start address of the pic stored
  19. '                      in the INLINE statement above.
  20. END
  21. '
  22. PROCEDURE deg_view(add%)  !  Shows a DEGAS picture stored at add%
  23.   FOR j%=0 TO 15          !  Set up the color
  24.     shade%=INT{add%+(j%*2+2)}
  25.     ~XBIOS(7,j%,shade%)
  26.   NEXT j%
  27.   BMOVE add%+34,XBIOS(2),32000  !  Move the pic to screen memory
  28. RETURN
  29.